/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package testImpl;

import com.prabhu.jeazyprops.bean.KeyValue;
import com.prabhu.jeazyprops.encryption.AES;
import com.prabhu.jeazyprops.props.BaseProps;
import java.io.File;

/**
 * Test Application for Displaying and Updating the Properties
 *
 * @author Prabhu Prabhakaran
 */
public class PropsTestGuiE extends BaseProps {

    private enum Property5_Enum {

        ONE, TWO, THREE, FOUR
    };
    public KeyValue Property1 = new KeyValue("Property1", "Boolean", true);
    public KeyValue Property2 = new KeyValue("Property2", "Integer", true);
    public KeyValue Property6 = new KeyValue("Property6", "Float", true);
    public KeyValue Property3 = new KeyValue("Property3", "String", true);
    public KeyValue Property4 = new KeyValue("Property4", "File", true);
    public KeyValue Property5 = new KeyValue("Property5", "Enum", true);
    private boolean property1;
    private int property2;
    private float property6;
    private String property3;
    private File property4;
    private Property5_Enum property5;
    public static PropsTestGuiE lPropsTest;

    public boolean isProperty1() {
        return property1;
    }

    public void setProperty1(boolean property1) {
        this.property1 = property1;
    }

    public int getProperty2() {
        return property2;
    }

    public void setProperty2(int property2) {
        this.property2 = property2;
    }

    public String getProperty3() {
        return property3;
    }

    public void setProperty3(String property3) {
        this.property3 = property3;
    }

    public File getProperty4() {
        return property4;
    }

    public void setProperty4(File property4) {
        this.property4 = property4;
    }

    public Property5_Enum getProperty5() {
        return property5;
    }

    public void setProperty5(Property5_Enum property5) {
        this.property5 = property5;
    }

    public float getProperty6() {
        return property6;
    }

    public void setProperty6(float property6) {
        this.property6 = property6;
    }

    /**
     * @param args the command line arguments
     */
    public static PropsTestGuiE getInstance() {
        if (lPropsTest == null) {
            lPropsTest = new PropsTestGuiE();
            lPropsTest.setEncryption(new AES());
            lPropsTest.loadProperties("test123.xml");
        }
        return lPropsTest;
    }

    public static void main(String[] args) {
        PropsTestGuiE.getInstance().printProperties();
        PropsTestGuiE.getInstance().displaySettings();
    }
}
